package com.hong.mp.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.hong.mp.pojo.User;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface UserMapper extends BaseMapper<User> {

    // 持久化层支持自定义方法
    @Select("select id,name,age,email from user where age < #{age}")
    public List<User> getUserList(Integer age);
}
